package com.park.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.park.dao.SysRelationMapper;
import com.park.model.SysRelationKey;
import com.park.service.SysRelationKeyService;

@Service
public class SysRelationKeyServiceImpl implements SysRelationKeyService {

	@Autowired
	private SysRelationMapper sysRelationKeyServiceMapper;
	@Override
	public int insert(List<SysRelationKey> sysRelationKey) {
		// TODO Auto-generated method stub
		return sysRelationKeyServiceMapper.insert(sysRelationKey);
	}

	@Override
	public int update(SysRelationKey sysRelationKey) {
		// TODO Auto-generated method stub
		return sysRelationKeyServiceMapper.update(sysRelationKey);
	}

	@Override
	public int delete(int id) {
		// TODO Auto-generated method stub
		return sysRelationKeyServiceMapper.deleteById(id);
	}

	@Override
	public int deleteByRoleId(int roleId) {
		// TODO Auto-generated method stub
		return sysRelationKeyServiceMapper.deleteByRoleId(roleId);
	}

}
